home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Source Code / Visual Basic Source Code.iso / vbsource / logixp1a / dsping.frm (.txt) next >
Visual Basic Form  |  1999-09-03  |  16KB  |  412 lines

  1. VERSION 5.00
  2. Begin VB.Form frmMain 
  3.    BorderStyle     =   1  'Fixed Single
  4.    Caption         =   "LOGIX PINGER"
  5.    ClientHeight    =   4245
  6.    ClientLeft      =   1740
  7.    ClientTop       =   2025
  8.    ClientWidth     =   5670
  9.    Icon            =   "dsPing.frx":0000
  10.    LinkTopic       =   "Form1"
  11.    MaxButton       =   0   'False
  12.    MinButton       =   0   'False
  13.    PaletteMode     =   1  'UseZOrder
  14.    Picture         =   "dsPing.frx":0442
  15.    ScaleHeight     =   4245
  16.    ScaleWidth      =   5670
  17.    StartUpPosition =   2  'CenterScreen
  18.    Begin VB.HScrollBar amount 
  19.       Height          =   255
  20.       LargeChange     =   10
  21.       Left            =   1440
  22.       Max             =   1000
  23.       Min             =   1
  24.       TabIndex        =   14
  25.       Top             =   2880
  26.       Value           =   1
  27.       Width           =   1215
  28.    End
  29.    Begin VB.TextBox Text5 
  30.       Height          =   315
  31.       Left            =   2880
  32.       TabIndex        =   13
  33.       Text            =   "1"
  34.       Top             =   360
  35.       Width           =   495
  36.    End
  37.    Begin VB.TextBox Text4 
  38.       Height          =   315
  39.       Left            =   2280
  40.       TabIndex        =   11
  41.       Text            =   "0"
  42.       Top             =   360
  43.       Width           =   495
  44.    End
  45.    Begin VB.TextBox Text3 
  46.       Height          =   315
  47.       Left            =   1800
  48.       TabIndex        =   10
  49.       Text            =   "0"
  50.       Top             =   360
  51.       Width           =   495
  52.    End
  53.    Begin VB.TextBox Text2 
  54.       Height          =   315
  55.       Left            =   1320
  56.       TabIndex        =   9
  57.       Text            =   "0"
  58.       Top             =   360
  59.       Width           =   495
  60.    End
  61.    Begin VB.TextBox Text1 
  62.       Height          =   315
  63.       Left            =   840
  64.       TabIndex        =   8
  65.       Text            =   "0"
  66.       Top             =   360
  67.       Width           =   495
  68.    End
  69.    Begin VB.CommandButton Command1 
  70.       Caption         =   "Ping Series"
  71.       Height          =   255
  72.       Left            =   120
  73.       TabIndex        =   7
  74.       Top             =   3360
  75.       Width           =   1215
  76.    End
  77.    Begin VB.TextBox txTTL 
  78.       Height          =   285
  79.       Left            =   5160
  80.       TabIndex        =   5
  81.       Text            =   "5"
  82.       Top             =   2880
  83.       Width           =   375
  84.    End
  85.    Begin VB.CommandButton btnPing 
  86.       Caption         =   "Ping Single"
  87.       Default         =   -1  'True
  88.       Height          =   255
  89.       Left            =   120
  90.       TabIndex        =   3
  91.       Top             =   2880
  92.       Width           =   1215
  93.    End
  94.    Begin VB.ListBox lbReturn 
  95.       Height          =   1500
  96.       Left            =   120
  97.       TabIndex        =   2
  98.       Top             =   1320
  99.       Width           =   5295
  100.    End
  101.    Begin VB.TextBox txIPAddress 
  102.       Height          =   285
  103.       Left            =   840
  104.       TabIndex        =   1
  105.       Text            =   "0.0.0.0"
  106.       Top             =   960
  107.       Width           =   4575
  108.    End
  109.    Begin VB.Line Line2 
  110.       X1              =   120
  111.       X2              =   5400
  112.       Y1              =   840
  113.       Y2              =   840
  114.    End
  115.    Begin VB.Label Label6 
  116.       BackStyle       =   0  'Transparent
  117.       Caption         =   "Ping series pings the set you have next to the series label.  It does not do anything with the single box."
  118.       ForeColor       =   &H000040C0&
  119.       Height          =   855
  120.       Left            =   1440
  121.       TabIndex        =   16
  122.       Top             =   3360
  123.       Width           =   4215
  124.    End
  125.    Begin VB.Line Line1 
  126.       X1              =   0
  127.       X2              =   5520
  128.       Y1              =   3240
  129.       Y2              =   3240
  130.    End
  131.    Begin VB.Label Label5 
  132.       BackStyle       =   0  'Transparent
  133.       Caption         =   "1"
  134.       ForeColor       =   &H000040C0&
  135.       Height          =   255
  136.       Left            =   2760
  137.       TabIndex        =   15
  138.       Top             =   2880
  139.       Width           =   615
  140.    End
  141.    Begin VB.Label Label4 
  142.       BackStyle       =   0  'Transparent
  143.       Caption         =   "-"
  144.       BeginProperty Font 
  145.          Name            =   "MS Sans Serif"
  146.          Size            =   12
  147.          Charset         =   0
  148.          Weight          =   700
  149.          Underline       =   0   'False
  150.          Italic          =   0   'False
  151.          Strikethrough   =   0   'False
  152.       EndProperty
  153.       ForeColor       =   &H000040C0&
  154.       Height          =   255
  155.       Left            =   2760
  156.       TabIndex        =   12
  157.       Top             =   360
  158.       Width           =   135
  159.    End
  160.    Begin VB.Label Label2 
  161.       BackStyle       =   0  'Transparent
  162.       Caption         =   "Series"
  163.       BeginProperty Font 
  164.          Name            =   "Arial"
  165.          Size            =   9.75
  166.          Charset         =   0
  167.          Weight          =   400
  168.          Underline       =   0   'False
  169.          Italic          =   0   'False
  170.          Strikethrough   =   0   'False
  171.       EndProperty
  172.       ForeColor       =   &H000040C0&
  173.       Height          =   255
  174.       Left            =   120
  175.       TabIndex        =   6
  176.       Top             =   360
  177.       Width           =   735
  178.    End
  179.    Begin VB.Label Label3 
  180.       Alignment       =   1  'Right Justify
  181.       BackStyle       =   0  'Transparent
  182.       Caption         =   "Time To Live (TTL) :"
  183.       ForeColor       =   &H000040C0&
  184.       Height          =   255
  185.       Left            =   3240
  186.       TabIndex        =   4
  187.       Top             =   2880
  188.       Width           =   1935
  189.    End
  190.    Begin VB.Label Label1 
  191.       Alignment       =   1  'Right Justify
  192.       BackStyle       =   0  'Transparent
  193.       Caption         =   "Single:"
  194.       ForeColor       =   &H000040C0&
  195.       Height          =   255
  196.       Left            =   120
  197.       TabIndex        =   0
  198.       Top             =   960
  199.       Width           =   615
  200.    End
  201. Attribute VB_Name = "frmMain"
  202. Attribute VB_GlobalNameSpace = False
  203. Attribute VB_Creatable = False
  204. Attribute VB_PredeclaredId = True
  205. Attribute VB_Exposed = False
  206. '*******************************************************************
  207. '   PingVB
  208. '   This application implements a TCP/IP network ping
  209. '   using the ICMP.DLL provided as part of Windows 95 and
  210. '   Windows NT.
  211. '   IP_STATUS codes returned from IP APIs
  212. '*******************************************************************
  213. Private Const IP_STATUS_BASE = 11000
  214. Private Const IP_SUCCESS = 0
  215. Private Const IP_BUF_TOO_SMALL = (11000 + 1)
  216. Private Const IP_DEST_NET_UNREACHABLE = (11000 + 2)
  217. Private Const IP_DEST_HOST_UNREACHABLE = (11000 + 3)
  218. Private Const IP_DEST_PROT_UNREACHABLE = (11000 + 4)
  219. Private Const IP_DEST_PORT_UNREACHABLE = (11000 + 5)
  220. Private Const IP_NO_RESOURCES = (11000 + 6)
  221. Private Const IP_BAD_OPTION = (11000 + 7)
  222. Private Const IP_HW_ERROR = (11000 + 8)
  223. Private Const IP_PACKET_TOO_BIG = (11000 + 9)
  224. Private Const IP_REQ_TIMED_OUT = (11000 + 10)
  225. Private Const IP_BAD_REQ = (11000 + 11)
  226. Private Const IP_BAD_ROUTE = (11000 + 12)
  227. Private Const IP_TTL_EXPIRED_TRANSIT = (11000 + 13)
  228. Private Const IP_TTL_EXPIRED_REASSEM = (11000 + 14)
  229. Private Const IP_PARAM_PROBLEM = (11000 + 15)
  230. Private Const IP_SOURCE_QUENCH = (11000 + 16)
  231. Private Const IP_OPTION_TOO_BIG = (11000 + 17)
  232. Private Const IP_BAD_DESTINATION = (11000 + 18)
  233. '   The next group are status codes passed up on status indications to
  234. '   transport layer protocols.
  235. Private Const IP_ADDR_DELETED = (11000 + 19)
  236. Private Const IP_SPEC_MTU_CHANGE = (11000 + 20)
  237. Private Const IP_MTU_CHANGE = (11000 + 21)
  238. Private Const IP_UNLOAD = (11000 + 22)
  239. Private Const IP_ADDR_ADDED = (11000 + 23)
  240. Private Const IP_GENERAL_FAILURE = (11000 + 50)
  241. Private Const MAX_IP_STATUS = 11000 + 50
  242. Private Const IP_PENDING = (11000 + 255)
  243. '   option information for network ping, we don't implement these here as this is
  244. '   a simple sample (simon says).
  245. Private Type ip_option_information
  246.     Ttl             As Byte     'Time To Live
  247.     Tos             As Byte     'Type Of Service
  248.     Flags           As Byte     'IP header flags
  249.     OptionsSize     As Byte     'Size in bytes of options data
  250.     OptionsData     As Long     'Pointer to options data
  251. End